home *** CD-ROM | disk | FTP | other *** search
- Path: mail2news.demon.co.uk!genesis.demon.co.uk
- From: Lawrence Kirby <fred@genesis.demon.co.uk>
- Newsgroups: comp.lang.c
- Subject: Re: CPU time measurement
- Date: Tue, 09 Jan 96 17:44:44 GMT
- Organization: none
- Message-ID: <821209484snz@genesis.demon.co.uk>
- References: <4cs60j$ilb@azure.acsu.buffalo.edu>
- Reply-To: fred@genesis.demon.co.uk
- X-NNTP-Posting-Host: genesis.demon.co.uk
- X-Newsreader: Demon Internet Simple News v1.27
- X-Mail2News-Path: genesis.demon.co.uk
-
- In article <4cs60j$ilb@azure.acsu.buffalo.edu>
- naras-r@acsu.buffalo.edu "Ram Prasad" writes:
-
- >Hi,
- >
- >Is there a standard acceptable way of measuring the
- >number of (milli)seconds that different pieces of code take
- >to execute in a system?
-
- clock() measures CPU time but there are no guarantees about the resolution
- you get from it, it usually depends on the internal clock granularity.
-
- >I found "getrusage" in the man pages, but I am not sure if
- >that's what I should use.
-
- Possibly but you should discuss Unix system services in
- comp.unix.programmer.
-
- --
- -----------------------------------------
- Lawrence Kirby | fred@genesis.demon.co.uk
- Wilts, England | 70734.126@compuserve.com
- -----------------------------------------
-